<?php
if (!isset($error)) {
    if ($step == 1) {
        ?>
        <div id="loader_cart" style="left: 392px;position: absolute;top: 203px;">
            <img src="<?php echo Configure::read('base_url'); ?>img/animation_processing.gif" alt="Processing Cart..." style="" />
        </div>
        <?php }if ($step == 2) { ?>
        <?php echo $html->script(array("jquery.min.js")); ?>
        <script type="text/javascript">
            jQuery.noConflict();
            jQuery(document).ready(function(){
                //jQuery("body").css("opacity","0.15");
                jQuery("#loader_cart").css("z-index","100");
                jQuery("#loader_cart").show("200");
                jQuery("#OrderExpressCheckoutConfirmation").submit();
            });		
        </script>
<?php $this->Html->addCrumb('Paypal checkout step2 ');?>
        <div id="loader_cart" style="left: 100px;position: absolute;top: 0px;">
            <img src="<?php echo Configure::read('base_url'); ?>img/animation_processing.gif" alt="Processing Cart..." style="" />
        </div>
        <div style="display: none;">
            <?php
            echo $form->create('Payment', array('type' => 'post', 'action' => 'expressCheckout/3', 'id' => 'OrderExpressCheckoutConfirmation'));
            //all shipping info contained in $result display it here and ask user to confirm.
            //pr($result);
            echo $form->end('Confirm Payment');
            ?>
        </div>
        <?php
    }
    if ($step == 3) {
        $this->Html->addCrumb('Paypal checkout');
        //show confirmation once again all information is contained in $result or $error
        echo '<h2>Thank you for your order from Authentic Avenue.</h2><br />';
        
    }
}
else
    echo $error;
?> 
